<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title>教练表</title>
		<style>
			table, th, td
				{			
					border: 1px solid black;
				    text-align:center; 
						}
		</style>
	</head>
	<body>
		<div>
			<table class="table">
				<tr>
					<th>编号</th>
					<th>名字</th>
					<th>电话</th>
					<th>QQ</th>
					<th>年龄</th>
					<th>性别</th>
					<th>头像</th>
					<th>呢称</th>
					
					<th>邮箱</th>
					<th>身份证</th>
					<th>地址</th>
					<th>流派</th>
					<th>自我介绍</th>
				  </tr>
				<tbody id="coach1" >
					<!-- <tr>
						<td>5</td>
						<td>呵呵 </td>
						<td>无</td>
						<td>manager6</td>
						<td>呵呵 </td>
						<td>无</td>
						<td>manager6</td>
						<td>5</td>
						<td>5</td>
						<td>呵呵 </td>
						<td>无</td>
						<td>无</td>
						<td>manager6</td>
					</tr> -->
			</tbody></table>
		</div>
		
		<script src="js/jquery.min.js"></script>
		<script type="text/javascript">
		 $(function(){
				search();
			});
			function search(){
				$.ajax({
					url:"yogaclub/byyid",
					type:"get",
					dataType:"json",
					success:function(data){
						alert(data);
						var content="";
						for(var i=0;i<data.length;i++){
							content+="<tr>"
							+"<td>"+data[i].cid+"</td>"
							+"<td>"+data[i].cname+"</td>"
							+"<td>"+data[i].ctel+"</td>"
							+"<td>"+data[i].cqq+"</td>"
							+"<td>"+data[i].cage+"</td>"
							+"<td>"+data[i].csex+"</td>"
							+"<td>"+data[i].cimage+"</td>"
							+"<td>"+data[i].cnickname+"</td>"
							+"<td>"+data[i].cmail+"</td>"
							+"<td>"+data[i].cidcard+"</td>"
							+"<td>"+data[i].caddrmes+"</td>"
							+"<td>"+data[i].cgenre+"</td>"
							+"<td>"+data[i].describe+"</td>"
							+"</tr>";
						}
						$("#coach1").html(content);
					}
				})
			} 
		
		
		</script>
	</body>
</html>
